import http from './http'

// 获取视频详情
const getVideoDetail = (id) => {
    return http.post(
        '/api/courseApi/getVideoDetail',
        { id },
        { headers: { act: 'getVideoDetail' } }
    )
}
// 收藏视频
const setCoursecollect = (id, type) => {
    return http.post(
        '/api/CourseApi/setCoursecollect',
        { course_id: id, type },
        { headers: { act: 'setCoursecollect' } }
    )
}
// 播放时长
const setUserCourseWatch = (data) => {
    return http.post(
        '/api/MemberApi/setUserCourseWatch',
        { ...data },
        { headers: { act: 'setCoursecollect' } }
    )
}
export {
    getVideoDetail,
    setCoursecollect,
    setUserCourseWatch
}